/*
 * 
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 as
 * published by the Free Software Foundation.
 *
 *
 *     __  ___   ______        ___       __          ___
 *    |  |/  /  /  __  \      /   \     |  |        /   \
 *    |  '  /  |  |  |  |    /  ^  \    |  |       /  ^  \
 *    |    <   |  |  |  |   /  /_\  \   |  |      /  /_\  \
 *    |  .  \  |  `--'  |  /  _____  \  |  `----./  _____  \
 *    |__|\__\  \______/  /__/     \__\ |_______/__/     \__\
 *
 *
 *
 * Created by Tommy on 15/3/12.
 * Copyright (c) 2015 com.koala. All rights reserved.
 */

#ifndef yangtao_ttid_h
#define yangtao_ttid_h


#ifndef  APP_NAME

#warning @"not defined APP_NAME will using exe file name"
#define APP_NAME    APP_FILE_NAME

#endif


#define kTTIDForAppStore                         TTID_GENERATOR(APP_NAME,@"201200")
#define kTTIDForWeiPhone                         TTID_GENERATOR(APP_NAME,@"225200")
#define kTTIDFor91Assist                         TTID_GENERATOR(APP_NAME,@"600438")
#define kTTIDForTongBuTui                        TTID_GENERATOR(APP_NAME,@"700397")
#define kTTIDForPP                               TTID_GENERATOR(APP_NAME,@"700407")



#define TTID_GENERATOR(_APPNAME_,_CHANNEL_)                  ([NSString stringWithFormat:@"%@@%@_iphone_%@",(_CHANNEL_),(_APPNAME_),APP_VERSION])

// 渠道推广ID
#ifdef DISTRIBUTE_WEIPHONE
#define TA_CHANNEL                               @"WeiPhone"
#elif DISTRIBUTE_91
#define TA_CHANNEL                               @"91Assist"
#elif DISTRIBUTE_TONGBUTUI
#define TA_CHANNEL                               @"TongBuTui"
#elif DISTRIBUTE_PP
#define TA_CHANNEL                               @"PP"
#else
#define TA_CHANNEL                               @"AppStore"
#endif



#ifdef DISTRIBUTE_WEIPHONE

#warning @"channel to weiphone"
#define kCurrentTTID                             kTTIDForWeiPhone

#elif DISTRIBUTE_91

#warning @"channel to 91"
#define kCurrentTTID                             kTTIDFor91Assist

#elif DISTRIBUTE_TONGBUTUI

#warning @"channel to tongbutui"
#define kCurrentTTID                             kTTIDForTongBuTui

#elif DISTRIBUTE_PP

#warning @"channel to pp"
#define kCurrentTTID                             kTTIDForPP

#else

#warning @"channel to appstore"
#define kCurrentTTID                             kTTIDForAppStore

#endif




#endif
